// Decompiled by DJ v3.9.9.91 Copyright 2005 Atanas Neshkov  Date: 4/12/2007 09:14:53
// Home Page : http://members.fortunecity.com/neshkov/dj.html  - Check often for new version!
// Decompiler options: packimports(3) 
// Source File Name:   RPanel.java

package utility;

import java.awt.*;
import java.util.Locale;

// Referenced classes of package de.escape.quincunx.i18n:
//            Localizable

public class RPanel extends Panel
    implements Localizable
{

    public RPanel()
    {
    }

    public RPanel(LayoutManager mgr)
    {
        super(mgr);
    }

    public RPanel(Locale l)
    {
        setLocale(l);
    }

    public RPanel(LayoutManager mgr, Locale l)
    {
        super(mgr);
        setLocale(l);
    }

    public void setLocale(Locale l)
    {
        super.setLocale(l);
        for(int c = getComponentCount() - 1; c >= 0; c--)
        {
            Component comp = getComponent(c);
            if(comp instanceof Localizable)
                ((Localizable)comp).setLocale(l);
        }

        invalidate();
    }

    public Locale getLocale()
    {
        try
        {
            return super.getLocale();
        }
        catch(IllegalComponentStateException _ex)
        {
            return null;
        }
    }
}